package cn.ithers.blog.repository;

import cn.ithers.blog.domain.EsArticle;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;

/**
 * @Author: zhanghuan
 * @date: 2020/10/26 12:16
 * @description:
 */

public interface EsArticleRepository extends ElasticsearchRepository<EsArticle, String> {

    /**
     * 搜索查询通过标题和内容
     */
    Page<EsArticle> findByTitleOrContent(String title, String content, Pageable pageable);
}
